package backend

import (
	"dockerview/backend/models"
	"encoding/json"
)

func (a App) ApiGetEndpointList() (list []models.Endpoint) {
	a.DB.Find(&list)
	return
}
func (a App) ApiAddEndpoint(params string)  {
	var Endpoint models.Endpoint
	_ = json.Unmarshal([]byte(params), &Endpoint)
	a.DB.Create(&Endpoint)

}
